package cn.xspace.app.filemg.bean;

import android.graphics.drawable.Drawable;

import com.google.gson.annotations.Expose;
import com.xspace.android.xafcommon.util.HypyUtil;

import java.io.Serializable;

public class FileInfo implements Serializable {
	private static final long serialVersionUID = -5682652967662480492L;

	public final static int STATUS_START = 0;
	public final static int STATUS_ING = 1;
	public final static int STATUS_FAIL = -1;
	public final static int STATUS_CANCELED = -2;
	public final static int STATUS_SUCC = 2;

	private String name;
	private String path;
	private long size;
	private boolean checkFlag;
	private String fileType;
	private transient Drawable apkIoc = null;
	private int status;
	private float progess;
	private String packageName;
	private String time;
	public String shotKey="";

	private boolean isFolder;
	public String getTime() {
		return time;
	}

	public void setTime(String time) {
		this.time = time;
	}

	@Expose
	private byte[] apkIocByte;

	public float getProgess() {
		return progess;
	}

	public void setProgess(float progess) {
		this.progess = progess;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
		try {
			String shortkey= HypyUtil.cn2py(name);
			this.shotKey=shortkey.toLowerCase();
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}

	public String getPath() {
		return path;
	}

	public void setPath(String path) {
		this.path = path;
	}

	public long getSize() {
		return size;
	}

	public void setSize(long size) {
		this.size = size;
	}

	public boolean isCheckFlag() {
		return checkFlag;
	}

	public void setCheckFlag(boolean checkFlag) {
		this.checkFlag = checkFlag;
	}

	public String getFileType() {
		return fileType;
	}

	public void setFileType(String fileType) {
		this.fileType = fileType;
	}

	public Drawable getApkIoc() {
		return apkIoc;
	}

	public void setApkIoc(Drawable apkIoc) {
		this.apkIoc = apkIoc;
	}

	public String getPackageName() {
		return packageName;
	}

	public void setPackageName(String packageName) {
		this.packageName = packageName;
	}

	public byte[] getApkIocByte() {
		return apkIocByte;
	}

	public void setApkIocByte(byte[] apkIocByte) {
		this.apkIocByte = apkIocByte;
	}

	public boolean isFolder() {
		return isFolder;
	}

	public void setFolder(boolean isFolder) {
		this.isFolder = isFolder;
	}
}
